package net.googlecode.demenkov.dao;

import net.googlecode.demenkov.domains.Friendship;
import net.googlecode.demenkov.domains.Person;

/**
 * DAO-interface for actions with friendships
 *
 * @author Demenkov Yura
 */
public interface FriendshipDAO extends GenericDAO<Friendship, Integer> {
    /**
     * Gets friendship by two persons
     *
     * @param personWhoSend person who proposed friendship
     * @param personWhoGet  person who confirmed friendship
     * @return friendship or null if there are no such friendship
     */
    public Friendship findFriendshipByPersons(Person personWhoSend, Person personWhoGet);
}
